package com.jyxd.web.controller.basic;

import com.jyxd.web.data.dto.HttpResult;
import com.jyxd.web.data.dto.NurseRecordFormDTO;
import com.jyxd.web.service.assessment.basic.NurseRecordFormOutPutService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.Map;

@Api(tags = "护理单三合一出量相关接口")
@Controller
@RequestMapping(value = "/nurseRecordFormOutPut")
public class NurseRecordFormOutPutController {

    @Autowired
    private NurseRecordFormOutPutService nurseRecordFormOutPutService;

    @ApiOperation("查询行出量数据")
    @RequestMapping(value = "/queryList", method = RequestMethod.POST)
    @ResponseBody
    public HttpResult queryList(@RequestBody Map<String, Object> map) {
        return nurseRecordFormOutPutService.queryList(map);
    }

    @ApiOperation("新增行出量数据")
    @RequestMapping(value = "/insert", method = RequestMethod.POST)
    @ResponseBody
    public HttpResult saveOrUpdate(@RequestBody NurseRecordFormDTO data) {
        return nurseRecordFormOutPutService.saveOrUpdate(data);
    }
}
